A typical computer system includes three basic elements, namely, a processor, a memory and an input/output system. The memory stores information, including data and instructions for processing the data, in a plurality of addressable storage locations. The processor enables information to be transferred, or fetched, to it, interprets the incoming information as either instructions or data, and processes the data in accordance with the instructions. The processor then transfers the processed data to addressed locations in the memory for storage.
The input/output system also communicates with the memory and the processor in order to transfer information into the computer system and to obtain the processed data from it. For example, the input/output system may obtain processed data and print it on paper or display it on a monitor for viewing by an operator Units comprising the input/output system normally operate in accordance with control information supplied to it by the processor. The control information defines the operations to be performed by the input/output units. Typical units comprising the input/output system include, for example, printers, video display terminals, and secondary information storage devices such as disk and tape storage units.
In a number of computer systems, virtual memory arrangements have been provided which permit the programmer to write a program without having to be concerned either about the amount of physical memory, that is, the number of addressable storage locations, actually included in the system, or about other programs that the system may be processing concurrently. Virtual memory arrangements permit the programmer to generate a program and data, which may be many times larger than the amount of physical memory which may be included in a practical system.
In a typical computer system that provides a virtual memory arrangement, the computer executes each program in the context of a process, with each process having an associated virtual address space. The virtual address space, in turn, has a plurality of virtual addressable locations each identified by a virtual address. Each process's virtual address space is divided into equal-sized pages, and the physical address space of the computer's memory is divided into equally-sized blocks, with the number of storage locations in a block corresponding to the number of addressable locations in a page of virtual address space. Normally, pages containing most of the information, including the program's instructions and data, in a process' virtual address space are maintained on a secondary storage device and transferred, under control of an operating system program, to blocks in the physical memory as they are needed. Typically, when information is transferred between memory and secondary storage, the amount of information transferred corresponds to that which will fill an integral number of blocks, when information is transferred to the memory, or which is in an integral number of blocks, when information is transferred from the memory for storage in secondary storage.
When a page is transferred from a secondary storage unit to the computer's physical memory, it may be stored in any block in the physical memory. During processing of a program, when a processor needs to transfer an item of information during either a fetch operation or a storage operation, the program provides an address in the virtual address space, which the operating system program and/or hardware normally contained in the processor translates to provide the address in memory of the item of information. Typically, a virtual address is divided into two parts, namely, a virtual page identifier, which identifies a page in the virtual address space, and an offset which identifies the displacement, into the page, to the virtual storage location containing the required information or into which data is to be stored. During translation, the virtual page identifier is used to identify the block in the physical memory, and the offset in the virtual address is used to identify the offset into the block in the physical memory to identify the storage location from which information is to be fetched or into which information is to be stored.